<template>
  <div class="index-footer">
    <el-row>
      <el-col :span="6">
        <img src="/static/images/public/seller.jpg" width="20px" height="15px" alt="">
        <p>商家</p>
      </el-col>
      <el-col :span="6">
        <img src="/static/images/public/find.jpg" width="20px" height="15px" alt="">
        <p>发现</p>
      </el-col>
      <el-col :span="6">
        <img src="/static/images/public/order.jpg" width="20px" height="15px" alt="">
        <p>订单</p>
      </el-col>
      <el-col :span="6" >
        <div @click="goLogin">
          <img src="/static/images/public/me.jpg" width="20px" height="15px" alt="">
          <p>我的</p>
        </div>
      </el-col>
    </el-row>
  </div>
</template>

<script>
  export default {
    name: "footNav",
    methods: {
      goLogin: function () {
        if (!this.$store.state.loginState){
          this.$router.push('/login');
        }else {
          this.$router.push('/persion');
        }
      }
    }
  }
</script>

<style scoped>
  .index-footer{
    width: 100%;
    height: 3rem;
    background: #fff;
    position: absolute;
    bottom: 0;
    color: #555;
  }
  .index-footer> div{
    height: 100%;
    text-align: center;
    font-size: 0.6rem;
  }
  .index-footer p{
    margin: 0;
  }
</style>
